home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / u_man / cat1 / passwd.z / passwd
Encoding:
Text File  |  2002-10-03  |  14.6 KB  |  331 lines

  1.  
  2.  
  3.  
  4. PPPPAAAASSSSSSSSWWWWDDDD((((1111))))                                                            PPPPAAAASSSSSSSSWWWWDDDD((((1111))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      passwd - change login password and password attributes
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.      ppppaaaasssssssswwwwdddd [ _n_a_m_e ]
  13.  
  14.      ppppaaaasssssssswwwwdddd [ ----llll | ----dddd ] [ ----nnnn _m_i_n ] [ ----ffff ] [ ----xxxx _m_a_x ] [ ----wwww _w_a_r_n ] _n_a_m_e
  15.  
  16.      ppppaaaasssssssswwwwdddd ----ssss [ ----aaaa ]
  17.  
  18.      ppppaaaasssssssswwwwdddd ----ssss [ _n_a_m_e ]
  19.  
  20. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  21.      The _p_a_s_s_w_d command changes the password or lists password attributes
  22.      associated with the user's login _n_a_m_e.  Additionally, super-users may use
  23.      _p_a_s_s_w_d to install or change passwords and attributes associated with any
  24.      login _n_a_m_e.  Passwords for NIS entries that don't override the _p_a_s_s_w_d
  25.      field with a local value must be changed with _y_p_p_a_s_s_w_d(1).
  26.  
  27.      When used to change a password, _p_a_s_s_w_d prompts ordinary users for their
  28.      old password, if any.  It then prompts for the new password twice. The
  29.      first time the new password is entered _p_a_s_s_w_d checks to see if the old
  30.      password has ``aged'' sufficiently. (Aging is not supported for NIS
  31.      entries, even if they have locally overridden passwords.)  Password
  32.      "aging" is the amount of time (usually a certain number of days) that
  33.      must elapse between password changes.  If ``aging'' is insufficient the
  34.      new password is rejected and _p_a_s_s_w_d terminates;  see _p_a_s_s_w_d(4).
  35.  
  36.      Assuming ``aging'' is sufficient, a check is made to insure that the new
  37.      password meets construction requirements.  When the new password is
  38.      entered a second time, the two copies of the new password are compared.
  39.      If the two copies are not identical the cycle of prompting for the new
  40.      password is repeated for at most two more times.
  41.  
  42.      Passwords must be constructed to meet the following requirements:
  43.  
  44.           Each password must have at least six characters.  Only the first
  45.           eight characters are significant.
  46.  
  47.           Each password must contain at least two alphabetic characters and at
  48.           least one numeric or special character.  In this case,
  49.           ``alphabetic'' means upper and lower case letters.
  50.  
  51.           Each password must differ from the user's login _n_a_m_e and any reverse
  52.           or circular shift of that login _n_a_m_e.  For comparison purposes, an
  53.           upper case letter and its corresponding lower case letter are
  54.           equivalent.
  55.  
  56.           New passwords must differ from the old by at least three characters.
  57.           For comparison purposes, an upper case letter and its corresponding
  58.           lower case letter are equivalent.
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. PPPPAAAASSSSSSSSWWWWDDDD((((1111))))                                                            PPPPAAAASSSSSSSSWWWWDDDD((((1111))))
  71.  
  72.  
  73.  
  74.      One whose effective user ID is zero is called a super-user; see _i_d(1),
  75.      and _s_u(1).  Super-users may change any password; hence, _p_a_s_s_w_d does not
  76.      prompt super-users for the old password.  Super-users are not forced to
  77.      comply with password aging and password construction requirements.  A
  78.      super-user can create a null password by entering a carriage return in
  79.      response to the prompt for a new password.  (This differs from ppppaaaasssssssswwwwdddd ----dddd
  80.      because the "password" prompt will still be displayed.)
  81.  
  82.      Any user may use the ----ssss option to show password attributes for his or her
  83.      own login _n_a_m_e.
  84.  
  85.      The format of the display will be:
  86.  
  87.           _n_a_m_e _s_t_a_t_u_s _u_i_d _g_i_d _d_i_r_e_c_t_o_r_y _s_h_e_l_l mm/dd/yy _m_i_n _m_a_x
  88.  
  89.      or, if password aging information is not present,
  90.  
  91.           _n_a_m_e _s_t_a_t_u_s _u_i_d _g_i_d _d_i_r_e_c_t_o_r_y _s_h_e_l_l
  92.  
  93.      or, if the entry is from NIS,
  94.  
  95.           _n_a_m_e _s_t_a_t_u_s _d_i_r_e_c_t_o_r_y _s_h_e_l_l
  96.  
  97.      where
  98.  
  99.      _n_a_m_e        The login ID of the user.
  100.  
  101.      _s_t_a_t_u_s      The password status of _n_a_m_e: "PS" stands for passworded or
  102.                  locked, "LK" stands for locked, and "NP" stands for no
  103.                  password.
  104.  
  105.      _u_i_d         Numerical user ID
  106.  
  107.      _g_i_d         Numerical group ID
  108.  
  109.      _d_i_r_e_c_t_o_r_y   Initial working directory
  110.  
  111.      _s_h_e_l_l       program to use as Shell when the user logs in.
  112.  
  113.      _m_m/_d_d/_y_y    The date password was last changed for _n_a_m_e.  (Because all
  114.                  password aging dates are determined using Greenwich Mean Time
  115.                  and /_e_t_c/_p_a_s_s_w_d stores the information in weeks, the date may
  116.                  differ by as much as a week depending upon the local time
  117.                  zone.)
  118.  
  119.      _m_i_n         The minimum number of days required between password changes
  120.                  for _n_a_m_e.
  121.  
  122.      _m_a_x         The maximum number of days the password is valid for _n_a_m_e.
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. PPPPAAAASSSSSSSSWWWWDDDD((((1111))))                                                            PPPPAAAASSSSSSSSWWWWDDDD((((1111))))
  137.  
  138.  
  139.  
  140.      Only a super-user can use the following options:
  141.  
  142.      ----llll        Locks password entry for _n_a_m_e, preventing all logins to that
  143.                account, except via the _r_h_o_s_t_s(4) mechanism.  Note that this
  144.                feature allows a denial of service attack that may require
  145.                booting from the miniroot to fix, as even the root accounts can
  146.                be locked out.
  147.  
  148.      ----dddd        Deletes password for _n_a_m_e.  The login _n_a_m_e will not be prompted
  149.                for password.
  150.  
  151.      ----nnnn        Set minimum field for _n_a_m_e.  The _m_i_n field contains the minimum
  152.                number of days between password changes for _n_a_m_e.  If _m_i_n is
  153.                greater than _m_a_x, the user may not change the password.  Always
  154.                use this option with the ----xxxx option, unless _m_a_x is set to -1 or
  155.                0 (aging turned off).  In that case, _m_i_n need not be set.
  156.  
  157.      ----xxxx        Set maximum field for _n_a_m_e.  The _m_a_x field contains the number
  158.                of days that the password is valid for _n_a_m_e.  The aging for
  159.                _n_a_m_e will be turned off immediately if _m_a_x is set to -1.  If it
  160.                is set to 0, then the user is forced to change the password at
  161.                the next login session and aging is turned off.  If _m_a_x is less
  162.                than _m_i_n, only the super-user can change this user's password.
  163.  
  164.      ----aaaa        Show password attributes for all entries.  Use only with ----ssss
  165.                option; _n_a_m_e must not be provided.
  166.  
  167.      ----ffff        Force the user to change password at the next login by expiring
  168.                the password for _n_a_m_e.
  169.  
  170.      ----wwww        The _w_a_r_n argument indicates the number of days before the
  171.                password expires that the user is warned.  This option is
  172.                supported only when the shadow passwords are in use.
  173.  
  174.      The behavior of the program is influenced by the content of
  175.      /_e_t_c/_d_e_f_a_u_l_t/_p_a_s_s_w_d if this file exists. The file is not supplied with
  176.      the system, but may be locally created and modified as need be.  If the
  177.      file is not present, the default behaviors described below are followed.
  178.      The following items are recognized:
  179.  
  180.      HHHHIIIISSSSTTTTOOOORRRRYYYYCCCCNNNNTTTT====nnnn
  181.           the number of previous passwords to retain in /_e_t_c/_p_a_s_s_w_d._h_i_s_t_o_r_y
  182.           for each system user.  The default behavior is to not retain any
  183.           (and to not create the file).  Previously used passwords found in
  184.           the history file may not be reused until HISTORYCNT other passwords
  185.           have been used, or HISTORYDAYS have elapsed.  The superuser may
  186.           supply any password for a user, including previously used ones.
  187.           This superuser supplied password is retained in the history file.
  188.           The maximum value is 25.
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. PPPPAAAASSSSSSSSWWWWDDDD((((1111))))                                                            PPPPAAAASSSSSSSSWWWWDDDD((((1111))))
  203.  
  204.  
  205.  
  206.      HHHHIIIISSSSTTTTOOOORRRRYYYYDDDDAAAAYYYYSSSS====nnnn
  207.           the number of days to retain and check for previously used
  208.           passwords.  The default behavior is to not retain any (and to not
  209.           create the history file).  The maximum value is 730 (approximately
  210.           two years).  If HISTORYCNT has not been specified and this parameter
  211.           has been, HISTORYCNT is set to 25.  Smaller values of HISTORYCNT may
  212.           be specified.
  213.  
  214.      MMMMAAAAXXXXWWWWEEEEEEEEKKKKSSSS====nnnn
  215.           the maximum number of weeks that the password is valid.  The default
  216.           behavior is to not set a value.  This is equivalent to the -_x _X_X
  217.           command line arguments.
  218.  
  219.      MMMMIIIINNNNWWWWEEEEEEEEKKKKSSSS====nnnn
  220.           minimum number of weeks between password changes (part of password
  221.           aging).  The default behavior is to not set a value.  This is
  222.           equivalent to the -_n _X_X command line arguments.
  223.  
  224.      PPPPAAAASSSSSSSSGGGGEEEENNNN====////ppppaaaatttthhhh
  225.           external program to be invoked to supply generated passwords.  The
  226.           default behavior is to not have such a program.  The program is
  227.           invoked in lieu of getting a password from the user.  The user must
  228.           select one of the choices offered.  The superuser may still supply
  229.           passwords, and is not presented with the generated passwords.  The
  230.           program must be specified as a full pathname (starts with /).  It
  231.           should produce the passwords on separate lines with a trailing new
  232.           line character on its stdout which is read by _p_a_s_s_w_d and presented
  233.           to the user.  Up to 20 generated passwords may be supplied by the
  234.           program.  If it generates more than 20, an error message is printed
  235.           and no passwords are presented.  No generating programs are supplied
  236.           with the system.
  237.  
  238.      PPPPAAAASSSSSSSSLLLLEEEENNNNGGGGTTTTHHHH====nnnn
  239.           minimum length of an acceptable password.  This defaults to 6, and
  240.           has a maximum value of 8.
  241.  
  242.      PPPPAAAASSSSSSSSWWWWDDDDVVVVAAAALLLLIIIIDDDDAAAATTTTEEEE====////ppppaaaatttthhhh
  243.           external program to be invoked to validate a new password.  The
  244.           default behavior is to not have such a program.  The program is
  245.           invoked after the basic validation steps discussed above. It must be
  246.           specified as a full pathname (starts with /).  The program receives
  247.           the new password in the clear, with a trailing new line, on its
  248.           standard input, which is closed after writing this one line.  The
  249.           _p_a_s_s_w_d program issues a _w_a_i_t(2) and obtains the exit status of the
  250.           external validation program.  Exit status of 0 indicates the new
  251.           password is acceptable, all other status values indicate an error
  252.           and the new password is not accepted.  The exit status of the
  253.           external validation program should be one of the values listed below
  254.           in the DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS section.  Passwords being changed by the
  255.           superuser are not subject to this validation.  No external
  256.           validation programs are supplied with the system.
  257.  
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. PPPPAAAASSSSSSSSWWWWDDDD((((1111))))                                                            PPPPAAAASSSSSSSSWWWWDDDD((((1111))))
  269.  
  270.  
  271.  
  272.      WWWWAAAARRRRNNNNWWWWEEEEEEEEKKKKSSSS====nnnn
  273.           number of weeks before password expiration to begin warning the
  274.           user.  The default behavior is to not set a value.  This is
  275.           equivalent to the -_w _X_X comand line arguments.
  276.  
  277. NNNNOOOOTTTTEEEE
  278.      Aging does not work with NIS entries, even if the password is locally
  279.      overridden.
  280.  
  281.      The _p_a_s_s_w_d command will silently delete commented lines (lines beginning
  282.      with #) from /etc/passwd.
  283.  
  284. FFFFIIIILLLLEEEESSSS
  285.      /etc/passwd, /etc/opasswd, /etc/.pwd.lock, /etc/shadow, /etc/oshadow,
  286.      /etc/default/passwd, /etc/passwd.history
  287.  
  288. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  289.      id(1M), login(1), su(1M).
  290.      yppasswd(1) for NIS passwords.
  291.      crypt(3C), passwd(4), shadow(4).
  292.  
  293. DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
  294.      The ppppaaaasssssssswwwwdddd command exits with one of the following values:
  295.  
  296.      0         SUCCESS.
  297.  
  298.      1         Permission denied.
  299.  
  300.      2         Invalid combination of options.
  301.  
  302.      3         File manipulation error.
  303.  
  304.      4         Old password or shadow password file cannot be recovered.
  305.  
  306.      5         Password file(s) busy.  Try again later.
  307.  
  308.      6         Invalid argument to option.
  309.  
  310.      7         Unexpected failure.  Password file unchanged.
  311.  
  312.      8         Unknown login name.
  313.  
  314.      9         Password aging is disabled.
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.  
  325.  
  326.  
  327.                                                                         PPPPaaaaggggeeee 5555
  328.  
  329.  
  330.  
  331.